Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
WHAT
🤖 Generated by Copilot at 331f473
The pull request switches the codebase and the template files to use ES modules syntax instead of CommonJS syntax, and adds the
typefield to thepackage.jsonfiles to enable this change. This improves the consistency, compatibility, and performance of the codebase and the generated CLI projects. The pull request also updates and reorganizes the dependencies and the shebang line to support the use of ES modules syntax.
🤖 Generated by Copilot at 331f473
WHY
Adds the necessary changes for loading dependencies via ESM
HOW
🤖 Generated by Copilot at 331f473
typefield with the valuemoduleto thepackage.jsonfiles (link, link)-Sand--no-warningsflags for node (link, link)requireandmodule.exportsstatements withimportandexportstatements (link, link, link, link, link, link, link, link, link, link, link, link)fsandurlmodules to read and parse thepackage.jsonfiles of the main project and the generated CLI projects (link, link)urlmodule to get the current directory of the file (link)import.metaobject to thecli-meow-helppackage as an option (link, link)dependenciesanddevDependenciessections in thepackage.jsonfile of the main project (link)pkgsarray in theutils/generate.jsfile to match the upgraded versions (link)Storeclass from thedata-storepackage todatastorein theutils/ask.jsfile to avoid confusion with the nativeStoreclass in Node.js (link)